.class Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;
.super Landroid/content/BroadcastReceiver;
.source "ElementWorkspaceControlBtn.java"


# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
    value = Lcom/nemustech/regina/ElementWorkspaceControlBtn;
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x2
    name = "SDStorageBroadcastReceiver"
.end annotation


# instance fields
.field final synthetic this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;


# direct methods
.method private constructor <init>(Lcom/nemustech/regina/ElementWorkspaceControlBtn;)V
    .locals 0
    .parameter

    .prologue
    .line 1774
    iput-object p1, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-direct {p0}, Landroid/content/BroadcastReceiver;-><init>()V

    return-void
.end method

.method synthetic constructor <init>(Lcom/nemustech/regina/ElementWorkspaceControlBtn;Lcom/nemustech/regina/ElementWorkspaceControlBtn$1;)V
    .locals 0
    .parameter "x0"
    .parameter "x1"

    .prologue
    .line 1774
    invoke-direct {p0, p1}, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;-><init>(Lcom/nemustech/regina/ElementWorkspaceControlBtn;)V

    return-void
.end method


# virtual methods
.method public onReceive(Landroid/content/Context;Landroid/content/Intent;)V
    .locals 12
    .parameter "context"
    .parameter "intent"

    .prologue
    const/4 v11, 0x1

    const/4 v10, 0x0

    .line 1777
    invoke-virtual {p2}, Landroid/content/Intent;->getAction()Ljava/lang/String;

    move-result-object v0

    .line 1778
    .local v0, action:Ljava/lang/String;
    const-string v8, "android.intent.action.EXTERNAL_APPLICATIONS_AVAILABLE"

    invoke-virtual {v8, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v8

    if-eqz v8, :cond_1

    .line 1779
    iget-object v8, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-static {v8}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$3200(Lcom/nemustech/regina/ElementWorkspaceControlBtn;)Landroid/content/pm/ResolveInfo;

    move-result-object v8

    if-nez v8, :cond_0

    iget-object v8, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-static {v8}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$3300(Lcom/nemustech/regina/ElementWorkspaceControlBtn;)Lcom/nemustech/regina/ReginaPreference;

    move-result-object v8

    invoke-virtual {v8}, Lcom/nemustech/regina/ReginaPreference;->getWorkspaceLeftAppPackageName()Ljava/lang/String;

    move-result-object v8

    if-eqz v8, :cond_0

    .line 1780
    iget-object v8, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-static {v8}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$3300(Lcom/nemustech/regina/ElementWorkspaceControlBtn;)Lcom/nemustech/regina/ReginaPreference;

    move-result-object v8

    invoke-virtual {v8}, Lcom/nemustech/regina/ReginaPreference;->getWorkspaceLeftAppIntentAction()Ljava/lang/String;

    move-result-object v3

    .line 1781
    .local v3, leftIntentAction:Ljava/lang/String;
    iget-object v8, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-static {v8}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$3300(Lcom/nemustech/regina/ElementWorkspaceControlBtn;)Lcom/nemustech/regina/ReginaPreference;

    move-result-object v8

    invoke-virtual {v8}, Lcom/nemustech/regina/ReginaPreference;->getWorkspaceLeftAppPackageName()Ljava/lang/String;

    move-result-object v4

    .line 1782
    .local v4, leftPackageName:Ljava/lang/String;
    iget-object v8, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-static {v8}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$3300(Lcom/nemustech/regina/ElementWorkspaceControlBtn;)Lcom/nemustech/regina/ReginaPreference;

    move-result-object v8

    invoke-virtual {v8}, Lcom/nemustech/regina/ReginaPreference;->getWorkspaceLeftAppClassName()Ljava/lang/String;

    move-result-object v2

    .line 1784
    .local v2, leftClassName:Ljava/lang/String;
    iget-object v8, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    iget-object v9, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-static {v9, v4, v2, v3}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$3400(Lcom/nemustech/regina/ElementWorkspaceControlBtn;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)Landroid/content/pm/ResolveInfo;

    move-result-object v9

    invoke-static {v8, v9}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$3202(Lcom/nemustech/regina/ElementWorkspaceControlBtn;Landroid/content/pm/ResolveInfo;)Landroid/content/pm/ResolveInfo;

    .line 1785
    iget-object v8, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-static {v8}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$3200(Lcom/nemustech/regina/ElementWorkspaceControlBtn;)Landroid/content/pm/ResolveInfo;

    move-result-object v8

    if-eqz v8, :cond_0

    .line 1786
    iget-object v8, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-static {v8}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$3200(Lcom/nemustech/regina/ElementWorkspaceControlBtn;)Landroid/content/pm/ResolveInfo;

    move-result-object v8

    iget-object v9, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-static {v9}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$700(Lcom/nemustech/regina/ElementWorkspaceControlBtn;)Lcom/nemustech/regina/ReginaLauncher;

    move-result-object v9

    invoke-virtual {v9}, Lcom/nemustech/regina/ReginaLauncher;->getPackageManager()Landroid/content/pm/PackageManager;

    move-result-object v9

    invoke-virtual {v8, v9}, Landroid/content/pm/ResolveInfo;->loadIcon(Landroid/content/pm/PackageManager;)Landroid/graphics/drawable/Drawable;

    move-result-object v8

    check-cast v8, Landroid/graphics/drawable/BitmapDrawable;

    invoke-virtual {v8}, Landroid/graphics/drawable/BitmapDrawable;->getBitmap()Landroid/graphics/Bitmap;

    move-result-object v8

    invoke-static {}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$3500()Landroid/graphics/Bitmap$Config;

    move-result-object v9

    invoke-virtual {v8, v9, v11}, Landroid/graphics/Bitmap;->copy(Landroid/graphics/Bitmap$Config;Z)Landroid/graphics/Bitmap;

    move-result-object v1

    .line 1787
    .local v1, icon:Landroid/graphics/Bitmap;
    iget-object v8, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-static {v8}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$800(Lcom/nemustech/regina/ElementWorkspaceControlBtn;)Lcom/nemustech/tiffany/world/TFPanel;

    move-result-object v8

    invoke-virtual {v8, v10, v1}, Lcom/nemustech/tiffany/world/TFPanel;->setImageResource(ILandroid/graphics/Bitmap;)Z

    .line 1791
    .end local v1           #icon:Landroid/graphics/Bitmap;
    .end local v2           #leftClassName:Ljava/lang/String;
    .end local v3           #leftIntentAction:Ljava/lang/String;
    .end local v4           #leftPackageName:Ljava/lang/String;
    :cond_0
    iget-object v8, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-static {v8}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$3600(Lcom/nemustech/regina/ElementWorkspaceControlBtn;)Landroid/content/pm/ResolveInfo;

    move-result-object v8

    if-nez v8, :cond_1

    iget-object v8, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-static {v8}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$3300(Lcom/nemustech/regina/ElementWorkspaceControlBtn;)Lcom/nemustech/regina/ReginaPreference;

    move-result-object v8

    invoke-virtual {v8}, Lcom/nemustech/regina/ReginaPreference;->getWorkspaceRightAppPackageName()Ljava/lang/String;

    move-result-object v8

    if-eqz v8, :cond_1

    .line 1792
    iget-object v8, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-static {v8}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$3300(Lcom/nemustech/regina/ElementWorkspaceControlBtn;)Lcom/nemustech/regina/ReginaPreference;

    move-result-object v8

    invoke-virtual {v8}, Lcom/nemustech/regina/ReginaPreference;->getWorkspaceRightAppIntentAction()Ljava/lang/String;

    move-result-object v6

    .line 1793
    .local v6, rightIntentAction:Ljava/lang/String;
    iget-object v8, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-static {v8}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$3300(Lcom/nemustech/regina/ElementWorkspaceControlBtn;)Lcom/nemustech/regina/ReginaPreference;

    move-result-object v8

    invoke-virtual {v8}, Lcom/nemustech/regina/ReginaPreference;->getWorkspaceRightAppPackageName()Ljava/lang/String;

    move-result-object v7

    .line 1794
    .local v7, rightPackageName:Ljava/lang/String;
    iget-object v8, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-static {v8}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$3300(Lcom/nemustech/regina/ElementWorkspaceControlBtn;)Lcom/nemustech/regina/ReginaPreference;

    move-result-object v8

    invoke-virtual {v8}, Lcom/nemustech/regina/ReginaPreference;->getWorkspaceRightAppClassName()Ljava/lang/String;

    move-result-object v5

    .line 1796
    .local v5, rightClassName:Ljava/lang/String;
    iget-object v8, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    iget-object v9, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-static {v9, v7, v5, v6}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$3400(Lcom/nemustech/regina/ElementWorkspaceControlBtn;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)Landroid/content/pm/ResolveInfo;

    move-result-object v9

    invoke-static {v8, v9}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$3602(Lcom/nemustech/regina/ElementWorkspaceControlBtn;Landroid/content/pm/ResolveInfo;)Landroid/content/pm/ResolveInfo;

    .line 1797
    iget-object v8, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-static {v8}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$3600(Lcom/nemustech/regina/ElementWorkspaceControlBtn;)Landroid/content/pm/ResolveInfo;

    move-result-object v8

    if-eqz v8, :cond_1

    .line 1798
    iget-object v8, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-static {v8}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$3600(Lcom/nemustech/regina/ElementWorkspaceControlBtn;)Landroid/content/pm/ResolveInfo;

    move-result-object v8

    iget-object v9, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-static {v9}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$700(Lcom/nemustech/regina/ElementWorkspaceControlBtn;)Lcom/nemustech/regina/ReginaLauncher;

    move-result-object v9

    invoke-virtual {v9}, Lcom/nemustech/regina/ReginaLauncher;->getPackageManager()Landroid/content/pm/PackageManager;

    move-result-object v9

    invoke-virtual {v8, v9}, Landroid/content/pm/ResolveInfo;->loadIcon(Landroid/content/pm/PackageManager;)Landroid/graphics/drawable/Drawable;

    move-result-object v8

    check-cast v8, Landroid/graphics/drawable/BitmapDrawable;

    invoke-virtual {v8}, Landroid/graphics/drawable/BitmapDrawable;->getBitmap()Landroid/graphics/Bitmap;

    move-result-object v8

    invoke-static {}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$3500()Landroid/graphics/Bitmap$Config;

    move-result-object v9

    invoke-virtual {v8, v9, v11}, Landroid/graphics/Bitmap;->copy(Landroid/graphics/Bitmap$Config;Z)Landroid/graphics/Bitmap;

    move-result-object v1

    .line 1799
    .restart local v1       #icon:Landroid/graphics/Bitmap;
    iget-object v8, p0, Lcom/nemustech/regina/ElementWorkspaceControlBtn$SDStorageBroadcastReceiver;->this$0:Lcom/nemustech/regina/ElementWorkspaceControlBtn;

    invoke-static {v8}, Lcom/nemustech/regina/ElementWorkspaceControlBtn;->access$1100(Lcom/nemustech/regina/ElementWorkspaceControlBtn;)Lcom/nemustech/tiffany/world/TFPanel;

    move-result-object v8

    invoke-virtual {v8, v10, v1}, Lcom/nemustech/tiffany/world/TFPanel;->setImageResource(ILandroid/graphics/Bitmap;)Z

    .line 1803
    .end local v1           #icon:Landroid/graphics/Bitmap;
    .end local v5           #rightClassName:Ljava/lang/String;
    .end local v6           #rightIntentAction:Ljava/lang/String;
    .end local v7           #rightPackageName:Ljava/lang/String;
    :cond_1
    return-void
.end method
